{# empty Twig template #}
{% extends'CNAMActimanBundle::layoutBody.html.twig' %}
{% block body %}
    <div class="row">
        <div class="col-lg-12">

        </div>
    </div><!-- /.row -->

    {% block content %}


        <div class="row">
            <div class="col-lg-12">
                <h2>Liste des Procedures Planifiées - </h2>
                
                <div class="table-responsive">
                    <table class="table table-bordered table-hover tablesorter">
                        <thead>
                            <tr>
                                <th>Procedure <i class="fa fa-sort"></i></th>
                                <th>Responsable <i class="fa fa-sort"></i></th>
                                <th>Date de Début <i class="fa fa-sort"></i></th>
                                <th>Date de Fin <i class="fa fa-sort"></i></th>
                                <th>Action <i class="fa fa-sort"></i></th>
                            </tr>
                        </thead>
                        <tbody>
                            {% for procedureplan in list_procedureplan %}
                                <tr>
                                    <td>{{ procedureplan.acprocedure.nomProcedure }}</td>
                                    {% if procedureplan.acprocedure.service != null %}
                                        <td>{{ procedureplan.acprocedure.service.nomService }}</td>
                                            {% elseif procedureplan.acprocedure.user!= null %}
                                                <td>{{ procedureplan.acprocedure.user.nomUser }}</td>
                                                {% else %}
                                                    <td>Pas de Responsable </td>
                                    {% endif %}  
                                    <td>{{ procedureplan.dateDebutProc|date("d/m/Y") }}</td>
                                    <td>{{ procedureplan.dateFinProc|date("d/m/Y") }}</td>
                                    <td><a href="{{path ('cnam_actiman_PlanProcedure_visuDetail',{'idpro': procedureplan.acprocedure.id})}}">Visualiser</a></td>
                                </tr>
                            {% endfor %}

                        </tbody>
                    </table>
                </div>
            </div>
        {% endblock%}
    {% endblock%}

